<!DOCTYPE html>
<html>
<head>
<title>用户修改</title>
<meta name="content-type" content="text/html; charset=UTF-8">
<div th:replace="/pub.html"></div>
<script type="text/javascript">
	var useredit_submitForm = function(dialog, user_datagrid, p) {
		if ($('#user_editForm').form('validate')) {
			$.post('/perm/user/edit', $("#user_editForm").serialize(), function(j) {
				if (j.success) {
					user_datagrid.datagrid('reload');
					dialog.dialog('destroy');
				}
				p.messager.show({
					title : '提示',
					msg : j.msg,
					timeout : 5000,
					showType : 'slide'
				});
			}, 'json').error(function() {
				$.messager.show({
					title : '提示',
					msg : '你的权限不够',
					timeout : 5000,
					showType : 'slide'
				});
			});
		}
	};
</script>
</head>

<body>
	<form id="user_editForm" method="post">
		<input type="hidden" name="id" value="${user.id}"/>
		<table style="width: 100%;" class="table table-hover table-condensed">
			<tr>
				<th>用户名</th>
				<td><input name="name" value="${user.username}" class="easyui-validatebox" data-options="required:true,missingMessage:'用户名必填'" /></td>
				<th>密码</th>
				<td><input name="pwd" type="password" value="${user.pwd}" class="easyui-validatebox" data-options="required:true,missingMessage:'密码必填'" /></td>
			</tr>
		</table>
	</form>
</body>
</html>